package cn.iocoder.yudao.module.social.api.content.dto;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import java.util.List;

/**
 * RPC 服务 - 内容创建 Request DTO
 *
 * @author 芋道源码
 */
@Schema(description = "RPC 服务 - 内容创建 Request DTO")
@Data
public class ContentReqDTO {

    @Schema(description = "作者编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024")
    @NotNull(message = "作者编号不能为空")
    private Long authorId;

    @Schema(description = "容器编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @NotNull(message = "容器编号不能为空")
    private Long containerId;

    @Schema(description = "标题", example = "这是一个标题")
    @Size(max = 200, message = "标题长度不能超过200个字符")
    private String title;

    @Schema(description = "内容", requiredMode = Schema.RequiredMode.REQUIRED, example = "这是内容正文")
    @NotBlank(message = "内容不能为空")
    @Size(max = 10000, message = "内容长度不能超过10000个字符")
    private String body;

    @Schema(description = "媒体文件列表", example = "[\"http://example.com/image1.jpg\", \"http://example.com/video1.mp4\"]")
    private List<String> media;

    @Schema(description = "状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @NotNull(message = "状态不能为空")
    private Integer status;

}
